package com.aier.common.service;

import java.sql.Timestamp;
import java.util.List;
import java.util.Map;

import com.aier.user.entity.Feedback;
import com.aier.user.entity.FeedbackContent;

public interface IFeedbackService {
    
    /**
     * 查询意见列表
     * @param uid
     * @return
     */
    Map<String, Object> searchFeedbackByUid(int page, int page_size, Long uid, int sortable);
    
    /**
     * 更新意见的评分
     * @param score
     * @param fbid
     * @return
     */
    int updateFeedbackByid(Short score, Long fbid);
    
    /**
     * 新增意见
     * @param uid
     * @param title
     * @param cdate
     * @return
     */
    int insertFeedback(Long uid, String title, Timestamp cdate, String content);
    
    /**
     * 新增回复
     * @param fbid
     * @param content
     * @param cdate
     * @param uid
     * @return
     */
    int insertFeedbackContent(Long fbid, String content, Timestamp cdate, Long uid, Short state, Long mid);
    
    /**
     * 查询意见的全部信息
     * @param fbid
     * @return
     */
    List<FeedbackContent> searchContent(Long fbid);
    
    /**
     * 根据用户uid查询名字
     * @param uid
     * @return
     */
    String searchRealname(Long uid);
    
    /**
     * 根据fbid查询意见
     * @param fbid
     * @return
     */
    Feedback searchFeedbackByFbid(Long fbid);
    
}
